Setting apparatus and setting method

ABSTRACT

A setting apparatus for making a setting to detect that a moving object in an image has passed a line set in the image accepts designation of one of a position and a partial region in an object region in the image, and makes a setting to detect that the designated position or partial region in the object region of the moving object in the image has passed the line set in the image.

BACKGROUND OF THE INVENTION

Field of the Invention

The present invention relates to a passage detection apparatus for anobject in an image, and a setting apparatus and a method for passagedetection.

Description of the Related Art

There is provided a technique of detecting an object in an image byperforming image analysis. An object is detected from each frame imageof a moving image using this technique, thereby performing objecttracking on the moving image. Furthermore, as an application of theobject tracking technique, a monitoring camera system or the likeperforms passage detection to determine whether an object has passedthrough a given region on an image plane.

For example, International Publication No. WO03/032622 discloses atechnique of performing passage detection by analyzing, after a personin a captured image is segmented and a segmented image region overlaps apreset boundary line, whether the person has traversed in a designateddirection.

As described above, if a segmented object has traversed in a designateddirection, it can be detected that the object has passed. However, it isimpossible to detect, with only this method, a case in which an objecthas gone beyond a designated boundary line. Furthermore, in this method,the timing when an apparatus determines that an object has passed may bedifferent from the timing when the user wants to be notified that theobject has passed.

SUMMARY OF THE INVENTION

According to an embodiment of the present invention, there is provided adetection apparatus, setting apparatus, and method which enable toflexibly set conditions for passage detection.

According to an embodiment of the present invention, there is provided asetting apparatus for making a setting to detect that a moving object inan image has passed a line set in the image, comprising: an acceptanceunit configured to accept designation of one of a position and a partialregion in an object region in the image; and a setting unit configuredto make a setting to detect that one of the position and the partialregion designated by the designation in the object region of the movingobject in the image has passed the line set in the image.

According to an embodiment of the present invention, there is provided apassage detection apparatus comprising: an acceptance unit configured toaccept designation of one of a position and a partial region in anobject region in an image; and a detection unit configured to detect,based on one of the position and the partial region designated by thedesignation in the object region of a moving object in the image, thatthe moving object in the image has passed a line set in the image.

Further features of the present invention will become apparent from thefollowing description of exemplary embodiments with reference to theattached drawings.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a view showing an example of the system configuration of apassage determination setting system according to the first embodiment;

FIG. 2 is a block diagram showing the hardware arrangement of an imagecapturing apparatus 1 according to the first embodiment;

FIG. 3 is a block diagram showing an example of the hardware arrangementof an information processing apparatus 2 according to the firstembodiment;

FIG. 4 is a block diagram showing an example of the functionalarrangement of the image capturing apparatus 1 according to the firstembodiment;

FIG. 5 is a block diagram showing an example of the functionalarrangement of the information processing apparatus 2 according to thefirst embodiment;

FIG. 6 is a view showing an example of a passage detection settingscreen according to the first embodiment;

FIG. 7 is a flowchart illustrating an example of processing by the imagecapturing apparatus according to the first embodiment;

FIG. 8 is a flowchart illustrating an example of processing by theinformation processing apparatus according to the first embodiment;

FIG. 9 is a flowchart illustrating processing for initializing orchanging passage detection settings according to the first embodiment;

FIG. 10 is a block diagram showing an example of the hardwarearrangement of an information processing apparatus 2 according to thesecond embodiment;

FIG. 11 is a view showing an example of a passage detection settingscreen according to the second embodiment;

FIG. 12 is a view showing representative examples of a determinationposition setting;

FIG. 13 is a block diagram showing an example of the systemconfiguration of a passage determination setting system according to thethird embodiment; and

FIG. 14 is a view showing an example of a passage detection settingscreen according to the fourth embodiment.

DESCRIPTION OF THE EMBODIMENTS

Preferred embodiments of the present invention will be described belowwith reference to the accompanying drawings.

A passage determination setting system according to the first embodimentwill be described based on the accompanying drawings. FIG. 1 is a viewshowing an example of the system configuration of a passagedetermination setting system according to the first embodiment.

Referring to FIG. 1, an image capturing apparatus 1 is, for example, anetwork camera connectable to a network. An information processingapparatus 2 is implemented by, for example, a personal computer, andmakes various settings for passage determination according to thisembodiment, thereby generating determination setting information forpassage determination. The image capturing apparatus 1 and theinformation processing apparatus 2 are connected to each other via, forexample, the Internet or a local area network.

A display device 3 displays a graphical user interface generated by theinformation processing apparatus 2 for making passage determinationsettings. Reference numeral 4 denotes an input device which is used bythe user to operate passage determination setting application softwareoperating on the information processing apparatus 2.

FIG. 2 is a block diagram showing an example of the hardware arrangementof the image capturing apparatus 1. As shown in FIG. 2, the imagecapturing apparatus 1 includes a CPU (Central Processing Unit) 11, a ROM(Read Only Memory) 12, a RAM (Random Access Memory) 13, an imagecapturing unit 14, a Net-IF 15, and a CPU bus 19.

The image capturing unit 14 includes a lens and a sensor, and outputs adigital image signal. The ROM 12 holds image capturing control softwareprograms and information. The CPU 11 executes the control softwareprograms stored in the ROM 12 to control respective devices. The RAM 13has a work area for the CPU 11, an area in which information is saved inerror processing, an area into which a control software program isloaded, an area for storing determination setting information (to bedescribed later), and the like.

The image capturing apparatus 1 can perform wired or wirelesscommunication with the information processing apparatus 2 via thenetwork interface (Net-IF) 15. The CPU bus 19 includes an address bus,information bus, and control bus. Processing associated with somefunctions (to be described later with reference to FIG. 4) of the imagecapturing apparatus 1 is implemented when the CPU 11 executes processingbased on the control software programs stored in the ROM 12.

FIG. 3 is a block diagram showing an example of the hardware arrangementof the information processing apparatus 2. As shown in FIG. 3, theinformation processing apparatus 2 includes a CPU 21, an HDD 22, a RAM23, a display control unit 24, an operation input unit 26, a networkinterface (Net-IF) 25, and a CPU bus 29. The HDD 22 holds informationprocessing control software programs and information. The CPU 21executes the control software programs stored in the HDD 22 to controlrespective devices.

The display control unit 24 performs display control of the graphicaluser interface displayed on the display device 3. The operation inputunit 26 receives an input signal from the input device 4. The RAM 23 hasa work area for the CPU 21, an area in which information is saved inerror processing, an area into which a control software program isloaded, and the like. The network interface (Net-IF) 25 performs wiredor wireless communication with the image capturing apparatus 1. The CPUbus 29 includes an address bus, information bus, and control bus.Processing associated with some functions (to be described later withreference to FIG. 5) of the information processing apparatus 2 isimplemented when the CPU 21 executes processing based on the controlsoftware programs.

FIG. 4 is a block diagram showing an example of the functionalarrangement of the image capturing apparatus 1. Each function shown inFIG. 4 is implemented by the hardware arrangement of the image capturingapparatus 1 shown in FIG. 2. For example, a lens 101, a sensor 102, andan A/D converter 103 shown in FIG. 4 are implemented as components ofthe image capturing unit 14 shown in FIG. 2. Each processing unit suchas an image encoding unit 110 is implemented when the CPU 11 executes aprogram stored in the ROM 12.

Referring to FIG. 4, the sensor 102 includes an image sensor, andconverts an optical image formed by the lens 101 into an electricsignal, thereby outputting it as a sensor signal. The A/D converter 103digitizes the sensor signal output from the sensor 102. An imagegeneration unit 104 generates an image using the digital signal outputfrom the A/D converter 103. The image encoding unit 110 encodes theimage generated by the image generation unit 104.

An object detection unit 120 performs object detection by performingimage analysis for the image (the image before encoding) generated bythe image generation unit 104, and outputs object information containingthe image features of an object detected in the image, and an objectarea indicating the range of the detected object in a predeterminedshape. Note that the object detection unit 120 may compare the imagewith the background by a background difference method, thereby detectingan object. Based on the object information (image features) output fromthe object detection unit 120 and the distance between objects in aplurality of images, an object determination unit 121 determines whetherthe objects detected in the plurality of images are identical.

A storage unit 122 is constituted by, for example, the RAM 13, and holdsdetermination setting information to be used by a decision unit 123 anda passage determination unit 130. The determination setting informationcontains position information indicating a position, in an object area,to be used for passage determination, and information for specifying aboundary line to be used for passage determination.

Using the determination setting information (position information) readout from the storage unit 122 and the object information (object area)detected by the object detection unit 120, the decision unit 123decides, for each object existing in an image, a determination positionin the object area to determine that the object has passed. The decisionunit 123 also associates, with each other, determination positions inthe object areas of the identical objects using a determination resultby the object determination unit 121. Based on the positionalrelationship between the boundary line indicated by the determinationsetting information stored in the storage unit 122 and the determinationpositions of the identical objects associated with each other by thedecision unit 123, the passage determination unit 130 determines whetherthe object has passed.

An image information transmission unit 140 transmits the image encodedby the image encoding unit 110, the object information detected by theobject detection unit 120, and the passage determination result of thepassage determination unit 130 to the information processing apparatus 2via the Net-IF 15.

A transmission/reception unit 150 transmits/receives the determinationsetting information to/from the information processing apparatus 2 viathe Net-IF 15. For example, the transmission/reception unit 150 receivesthe determination setting information set or updated in the informationprocessing apparatus 2 to write it in the storage unit 122, and readsout the current determination setting information from the storage unit122 to transmit it to the information processing apparatus 2.

FIG. 5 is a block diagram showing an example of the functionalarrangement of the information processing apparatus 2. Each unit shownin FIG. 5 is implemented when, for example, the CPU 21 of theinformation processing apparatus 2 executes a program loaded from theHDD 22 into the RAM 23.

Referring to FIG. 5, an image information reception unit 201 receives,via the Net-IF 25, the information transmitted by the image informationtransmission unit 140 of the image capturing apparatus 1. An imagedecoding unit 202 decodes an encoded image contained in the informationreceived by the image information reception unit 201, and provides thedecoded image to an image generation unit 230. A determination resultconfirmation unit 203 confirms the passage determination resultcontained in the information received by the image information receptionunit 201, and provides it to the image generation unit 230.

An object information confirmation unit 204 confirms the objectinformation (object area) contained in the information received by theimage information reception unit 201, and provides it to the imagegeneration unit 230.

An operation reception unit 210 is implemented by the operation inputunit 26. The operation reception unit 210 accepts an operation inputfrom the input device 4 through the operation input unit 26. A settinginformation generation unit 211 generates/updates the determinationsetting information (the determination position and boundary line in theobject area) for passage determination based on the operation receivedby the operation reception unit 210. A transmission/reception unit 220transmits the determination setting information generated/updated by thesetting information generation unit 211 to the image capturing apparatus1 via the Net-IF 25, and receives the current determination settinginformation from the image capturing apparatus 1 via the Net-IF 25.

The image generation unit 230 generates an image to be displayed on thedisplay device 3 using the decoded image, object information (objectarea), determination setting information, and passage determinationresult. A display output unit 231 is implemented by the display controlunit 24, and outputs the image generated by the image generation unit230 to the display device 3.

FIG. 6 shows an example of a passage determination setting screendisplayed on the display device 3 by the display control unit 24 ordisplay output unit 231. Referring to FIG. 6, an image display area 310for displaying an image captured by the image capturing apparatus 1 isdisplayed on a display screen 300 of the display device 3. A boundaryline 320 is a line for performing passage detection, and is generallycalled a trip wire.

An object 321 indicates a captured person, and an object area 322indicates the area of the detected object 321. The object area is arectangle circumscribing the object 321. Note that although the objectarea is formed by a rectangle in this embodiment, the present inventionis not limited to this, and it is possible to apply a predeterminedshape such as an ellipse. Furthermore, decision of an object area iswell known.

A menu 330 is used to set a position in the detected object area todetermine, if the position has passed the boundary line 320, that theobject has passed.

Note that in the screen shown in FIG. 6, for descriptive convenience, apoint is set as a determination position to perform passagedetermination, a list of a plurality of settable determination positionsis displayed, and a determination position is selected by a radiobutton. In FIG. 6, it is possible to select, as a determinationposition, one of the central, upper left, lower left, upper right, andlower right positions of the object area. The menu 330 is not limited tothat shown in FIG. 6, as a matter of course. Another example of adetermination position setting will be described later in the secondembodiment. Moreover, in the menu 330, the currently selected one of theplurality of determination positions which can be designated forselection is explicitly indicated by a filled radio button so that theuser can identify it (the “central” determination position is currentlyselected in FIG. 6).

Note that in order for the user to identify the object which has beendetermined to have passed the boundary line 320, the image generationunit 230 changes the display mode (for example, the display color of theframe of the object area) of the object area of the object based on thepassage determination information provided by the determination resultconfirmation unit 203.

FIGS. 7 and 8 are flowcharts illustrating an example of the overallprocessing procedure of the system in the presence of the passagedetection settings from when an image is captured until an objectdetection result is displayed. Processing by the image capturingapparatus 1 will first be described with reference to FIG. 7.

The transmission/reception unit 150 reads out the determination settinginformation for passage determination from the storage unit 122 (stepS1). The determination setting information contains boundary lineinformation for uniquely deciding the boundary line 320 based oncoordinate information and the like on an image plane, and positionsetting information indicating a determination position in the objectarea 322 to be used to determine whether the object has passed theboundary line 320. Note that the determination position is selectedfrom, for example, the determination positions displayed in the menu 330shown in FIG. 6, and the boundary line 320 can be designated within theimage display area 310 shown in FIG. 6.

The transmission/reception unit 150 transmits the readout determinationsetting information to the information processing apparatus 2 (step S2).After that, processing in steps S3 to S9 to be described below isrepeated until a change in passage determination settings is receivedfrom the information processing apparatus 2 in step S10 or an endinstruction is received in step S11.

The A/D converter 103 converts, into a digital signal, an electricsignal received by the sensor 102 through the lens 101, and the imagegeneration unit 104 of the succeeding stage generates a digital image(captured image) based on the digital signal (step S3). The generateddigital image is copied, and sent to the image encoding unit 110 andobject detection unit 120.

The object detection unit 120 detects object information from thedigital image by performing image analysis, and the image informationtransmission unit 140 transmits the detected object information to theinformation processing apparatus 2 (step S4). The object informationindicates the position (coordinates) and size of the detected objectarea. The image encoding unit 110 encodes the digital image into animage format represented by, for example, JPEG, and the imageinformation transmission unit 140 transmits the encoded image to theinformation processing apparatus 2 (step S5).

Note that to transmit the object information to the informationprocessing apparatus 2, the object information itself may betransmitted. The present invention, however, is not limited to this. Forexample, the object detection unit 120 may send the object informationto the image encoding unit 110, which may include the object informationin the header of the encoded image, thereby transmitting the objectinformation. Furthermore, although the processes in steps S4 and S5 aredescribed as successive processes in the flowchart for descriptiveconvenience, it is apparent that they can be parallelly executed.

The object area contained in the object information need only beinformation for uniquely deciding an area, on a plane, which surroundsthe detected object in an arbitrary shape. If, for example, the area ofthe detected object is normalized to a rectangle, the object informationmay represent the object area using the coordinates of the upper rightcorner and those of the lower left corner.

Referring back to FIG. 7, since it is necessary to consider the temporalcontinuity of the object to perform passage detection, it is necessaryto compare the object with an object detected in an immediatelypreceding captured image. The object determination unit 121 thusconfirms whether there is an image having undergone object detection(step S6). If there is no image having undergone object detection, thatis, immediately after initialization or start of the apparatus, there isno object to be compared with, and thus the process advances to stepS10.

On the other hand, if there is an image to be compared with, the objectdetermination unit 121 confirms whether the detected object is identicalwith the object detected in the comparison target image (step S7). Ifthe objects are not identical, the detected object cannot be identifiedas an object which has passed the boundary line, and thus the processadvances to step S10. Whether the objects are identical can bedetermined by comparing the positions and sizes of the objects.

If the objects are identical, the decision unit 123 decides adetermination position for passage detection for each object (objectarea) based on the above-described detection position information (stepS8). The determination position is decided based on the information ofthe position and size (for example, the coordinates of diagonal pointsof a rectangle) of the detected object area 322, and the positionsetting information of the determination position (for example, thecentral position) read out from the storage unit 122. Based on thedetermination position for each object and the boundary lineinformation, the passage determination unit 130 determines whether theobject has passed the boundary line, and then transmits thedetermination result to the information processing apparatus 2 (stepS9). Note that in step S9, only if it is determined that the object haspassed the boundary line, the determination result is transmitted, andif it is determined that the object has not passed the boundary line, itis not necessary to transmit the determination result.

The above-described processing in steps S3 to S9 is repeated until thepassage determination setting information is updated (while NOs aredetermined in steps S10 and S11). For example, if the passagedetermination setting information has been updated (YES in step S10),for example, if updated determination setting information is receivedfrom the information processing apparatus 2, the process returns to stepS1, and starts again the processing from step S1 to perform processingusing the new determination setting information. If an end instructionis given (YES in step S11), the process is terminated. The endinstruction is received from, for example, the information processingapparatus 2.

Processing by the information processing apparatus 2 will be describednext with reference to FIG. 8. In the information processing apparatus2, the image information reception unit 201 receives, from the imagecapturing apparatus 1, the determination setting information transmittedin step S2, the object information transmitted in step S4, the encodedimage transmitted in step S5, and the passage detection determinationresult transmitted in step S9 (step S21). The pieces of information neednot be received at the same time in step S21, and each piece ofinformation need only be received, as appropriate. The objectinformation confirmation unit 204 specifies the position (coordinates)and size of the detected object area based on the received objectinformation (step S22). The image decoding unit 202 decodes the receivedencoded image (step S23).

The image generation unit 230 generates an image by superimposing theobject area specified in step S22 and the passage determination resultreceived in step S21 on the image decoded in step S23, and outputs thegenerated image to the display device 3 via the display output unit 231(step S24). Based on the determination setting information received instep S21, the image generation unit 230 generates display elements ofthe menu 330 and sets them as part of the image (step S25). Displaycontents at this time are as described above with reference to FIG. 6.Note that the determination position (currently applied determinationposition) obtained from the determination setting information receivedfrom the image capturing apparatus 1 is displayed by the filled radiobutton in the menu 330. Note that the menu 330 may be superimposed anddisplayed on the decoded image, or may be displayed in an area differentfrom the decoded image, as shown in FIG. 6.

The above processing in steps S21 to S25 is repeated until the passagedetermination setting information is updated (for example, set orupdated in processing to be described later with reference to aflowchart shown in FIG. 9) (while NOs are determined in steps S26 andS27). If another determination position is selected in the menu 330, orthe boundary line 320 is moved/rotated to update the passagedetermination setting information (YES in step S26), the processadvances to step S28. In this case, the transmission/reception unit 220transmits the updated determination setting information to the imagecapturing apparatus 1 (step S28), and the returns the process to stepS21. The image capturing apparatus 1 receives the determination settinginformation in step S10 of FIG. 7.

If an end instruction is given through the user interface (YES in stepS27), the transmission/reception unit 220 transmits an end instructionto the image capturing apparatus 1 (step S29), and the process isterminated.

FIG. 9 is a flowchart illustrating an example of the processingprocedure of the information processing apparatus 2 when initializing orchanging passage detection settings. The transmission/reception unit 220confirms whether boundary line information (information for specifyingthe boundary line 320) has already been stored in the storage unit 122(step S31). This can be done by, for example, determining whether thedetermination setting information received from the image capturingapparatus 1 contains boundary line information. If no boundary lineinformation is set, the transmission/reception unit 220 stands by untilboundary line information is input to the information processingapparatus 2 (step S32).

If boundary line information has been stored (YES in step S31) or hasbeen input to the information processing apparatus 2 (YES in step S32),the transmission/reception unit 220 confirms whether the boundary lineinformation has been newly input or changed (step S33). If it isdetermined that the boundary line information has been newly input orchanged, the transmission/reception unit 220 transmits the boundary lineinformation as an update instruction to the image capturing apparatus 1(step S34). In this way, the updated boundary information is saved inthe storage unit 122 of the image capturing apparatus 1.

The transmission/reception unit 220 confirms whether position settinginformation indicating a determination position, in the object area, toperform passage detection determination has already been stored in thestorage unit 122 (step S35). The position setting information is alsocontained in the determination setting information received from theimage capturing apparatus 1. If there is no position information, theabove processing is repeated until a determination position is input/setthrough the menu 330 (NO in step S35 and NO in step S36). On the otherhand, if position information has been stored (YES in step S35) orposition information has been input (YES in step S36), thetransmission/reception unit 220 confirms whether the determinationposition setting information has been changed (step S37).

If the determination position setting information has been changed ornewly input, the transmission/reception unit 220 transmits the positioninformation as an update instruction to the image capturing apparatus 1(step S38). In this way, the updated determination position is saved inthe storage unit 122 of the image capturing apparatus 1. The aboveprocessing is repeated until an end instruction is given (step S39).

Note that the image capturing apparatus 1 detects an update notificationby receiving the update instruction transmitted in step S34 or S38 viathe transmission/reception unit 150. Upon detecting the updatenotification, the process branches to YES in step S10 of FIG. 7, therebystarting passage determination processing using the new determinationsetting information.

With the above arrangement, the user can instruct the position of theobject to be determined in passage detection that the object has passedthe boundary line, thereby enabling to set desired passage determinationconditions.

An example of a passage determination setting system according to thesecond embodiment will be described below with reference to theaccompanying drawings. Note that a description of points according tothe above-described first embodiment will be omitted. The maindifference from the first embodiment is that it is possible tosuperimpose and display, on an object area 322, a determination positionset by the user to determine in an information processing apparatus 2that an object has passed a boundary line.

The functional blocks of an image capturing apparatus 1 according to thesecond embodiment are the same as those shown in FIG. 4. Note that animage information transmission unit 140 transmits position information,for each object area, decided by a decision unit 123. FIG. 10 is a blockdiagram showing an example of the functional arrangement of theinformation processing apparatus 2 according to the second embodiment.In FIG. 10, the same components as those according to the firstembodiment (FIG. 5) have the same reference numerals.

A determination position confirmation unit 940 confirms positioninformation for each object area, which has been received by an imageinformation reception unit 201 from the image capturing apparatus 1, andprovides the information to an image generation unit 230. Newly addingthe determination position confirmation unit 940 enables the imagegeneration unit 230 to superimpose and display a detection position usedfor passage detection determination for each object area extracted by anobject information confirmation unit 204, thereby generating an image.

FIG. 11 is a view showing an example of a passage determination settingscreen displayed on a display device 3. The same display elements asthose on the passage determination screen (FIG. 6) described in thefirst embodiment have the same reference numerals as those in FIG. 6.Reference numeral 340 denotes a determination position which has beenused for passage detection determination and is superimposed anddisplayed. This arrangement allows the user to readily confirm that theobject has passed the boundary line as set. With respect tosuperimposition and display of the determination position used forpassage detection determination, display of the determination positionis different from that of an object area (for example, in a differentshape and color). This enables the user to readily discriminate betweenthe object area and display of the position used for passage detectiondetermination, thereby allowing easier recognition. In a menu 330,determination positions within a rectangle are represented by graphicsinstead of characters such as “central” and “upper left” shown in FIG.6. This menu display allows the user to more intuitively select adetermination position.

Note that in the above-described first and second embodiments, a pointwithin the object area is used as a determination position to determinewhether the object has passed the boundary line. The present invention,however, is not limited to this. Some types of determination positionswill be explained below.

FIG. 12 shows representative determination position settings. Although apoint has been used as a determination position above, it is alsopossible to make determination using a line or plane (area), as shown inFIG. 12, as a matter of course. The user may set a type of determinationposition (a point, line, or plane). Furthermore, all determinationpositions represented by points, lines, and planes may be displayed inthe menu 330, and then the user may be prompted to select a desireddetermination position.

If, for example, a rectangle is used as an object area and a point isused as a determination position, it is possible to set “barycenter orcenter”, “upper left corner”, “lower left corner”, “upper right corner”,or “lower right corner” of the object area. Alternatively, if arectangle is used as an object area and a line is used as adetermination position, it is possible to set “upper edge”, “left edge”,“right edge”, “lower edge”, “vertical center”, or “horizontal center”.Furthermore, if a rectangle is used as an object area and a plane isused as a determination position, it is possible to set an “upper left”,“upper right”, “lower left”, or “lower right” partial region, or “whole”indicating the whole region.

If determination is performed using a line or plane, it may bedetermined that the object has passed the boundary line when all or someof the set positions have passed the boundary line. Therefore, thedetermination method may be decided in advance, or a user interface forenabling the user to make a setting may be additionally provided. Notethat in an object area 322 when a plane (area) is used as adetermination position, it is possible to indicate, to the user, a setdetermination position (area) set in the object area 322 by filling itwith a predetermined translucent color.

A passage determination setting system according to the third embodimentwill be described below with reference to the accompanying drawings. Themain difference from the first and second embodiments is that aninformation processing apparatus 2 can perform passage detection basedon encoded images saved in a recording medium or the like.

FIG. 13 is a block diagram showing an example of the functionalarrangement of the system. In FIG. 13, the same components as those inthe first and second embodiments (FIGS. 4, 5, and 10) have the samereference numerals as those in FIGS. 4, 5, and 10.

Reference numeral 1200 denotes a passage determination setting system;and 1201, an encoded image storage unit storing encoded images. An imagedecoding unit 202 decodes an encoded image stored in the encoded imagestorage unit 1201, and provides the thus obtained image to an objectdetection unit 120 and image generation unit 230. The operations of anobject determination unit 121, decision unit 123, and passagedetermination unit 130 are as described above in the first embodimentbut respective processing results are provided to the image generationunit 230. The image generation unit 230 displays a user interface shownin FIG. 6 or 11 on a display device 3.

A setting information access unit 1211 reads out determination settinginformation from a storage unit 122, and supplies position informationto the decision unit 123 and information for specifying a boundary lineto the passage determination unit 130 and image generation unit 230.

With this arrangement, the passage determination setting system 1200 canperform display as described with reference to FIG. 6 or 11 using theencoded images stored in the encoded image storage unit 1201. Thepassage determination setting system 1200, therefore, allows the user toreadily confirm and change passage determination conditions for imagesstored in the past. Note that the arrangement shown in FIG. 13 mayreceive an encoded image output from the image capturing apparatus 1,instead of reading out an encoded image from the encoded image storageunit 1201. In this case, the image capturing apparatus 1 need onlyencode and transmit a captured image, and need not have a function ofexecuting passage determination processing.

A passage determination setting system according to the fourthembodiment will be described below with reference to the accompanyingdrawings. Note that a description of points according to the first,second, or third embodiment will be omitted. The main difference fromthe first, second, and third embodiments is that a passage direction isadded to processing, by an image capturing apparatus 1, of determiningwhether an object has passed a boundary line, and passage determinationsettings in an information processing apparatus 2.

A setting information generation unit 211 of the information processingapparatus 2 according to the fourth embodiment generates/updatesdetermination setting information added with a passage direction basedon an operation received from an operation reception unit 210. Atransmission/reception unit 220 transmits the determination settinginformation including the passage direction to the image capturingapparatus 1 to save it in a storage unit 122, and receives the currentdetermination setting information from the image capturing apparatus 1.

The difference of a passage detection processing procedure according tothe fourth embodiment from the first embodiment will be described withreference to FIG. 7. Determination setting information read out by atransmission/reception unit 150 in step S1 includes a passage directionsetting. A passage determination unit 130 determines (step S9) whetheran object has passed a boundary line, as follows. That is, based on adetermination position, boundary line information, and a passagedirection setting for each object, it is determined that the object haspassed a boundary line if the determination position has passed theboundary line and the moving direction of the determination positionwith respect to the boundary line coincides with the passage directionsetting. In other states, it is determined that the object has notpassed the boundary line. The determination result is transmitted to theinformation processing apparatus 2.

FIG. 14 shows an example of a passage determination setting screenaccording to the fourth embodiment. FIG. 14 is different from FIG. 6 inthat a passage direction 350 is displayed on a boundary line 320, and apassage direction menu 351 for selecting, as a passage direction, asetting of both directions, the right direction, or the left directionwith respect to a direction from the start point to the end point of theboundary line. Display of a passage direction by the arrow of thepassage direction 350 changes depending on selection through the passagedirection menu 351.

Referring to FIG. 14, a setting of both directions, the right direction,or the left direction with respect to a direction from the start point(a closed circle) to the end point (an open circle) is selectable.Furthermore, a closed circle on the left side of an arrow indicates thata setting of both the directions has been selected. If a setting of theright direction is selected, the closed circle on the left side of thedouble-headed arrow is changed to an open circle, and an open circle onthe left side of a right arrow is changed to a closed circle.

In FIG. 14, one boundary line 320 is shown. It is, however, possible toset a plurality of boundary lines 320, and set a different passagedirection for each boundary line. If there are a plurality of boundarylines, a passage direction set for a selected boundary line is reflectedin the passage direction menu 351. The user can confirm a passagedirection selection state as a passage determination condition, andselect and set a passage direction using the passage direction menu 351,similarly to setting and changing of a determination position using amenu 330 as described above.

Note that in each of the above-described embodiments, passagedetermination conditions may be commonly set for all objects, or may beindividually set for each object. To make passage determinationconditions settable for each object, it is only necessary to specifyindividual objects by face recognition or the like, assign identifiersto the respective objects, and hold passage determination conditions inassociation with the identifiers, respectively.

OTHER EMBODIMENTS

Embodiments of the present invention can also be realized by a computerof a system or apparatus that reads out and executes computer executableinstructions recorded on a storage medium (e.g., non-transitorycomputer-readable storage medium) to perform the functions of one ormore of the above-described embodiments of the present invention, and bya method performed by the computer of the system or apparatus by, forexample, reading out and executing the computer executable instructionsfrom the storage medium to perform the functions of one or more of theabove-described embodiments. The computer may comprise one or more of acentral processing unit (CPU), micro processing unit (MPU), or othercircuitry, and may include a network of separate computers or separatecomputer processors. The computer executable instructions may beprovided to the computer, for example, from a network or the storagemedium. The storage medium may include, for example, one or more of ahard disk, a random-access memory (RAM), a read only memory (ROM), astorage of distributed computing systems, an optical disk (such as acompact disc (CD), digital versatile disc (DVD), or Blu-ray Disc (BD)™),a flash memory device, a memory card, and the like.

While the present invention has been described with reference toexemplary embodiments, it is to be understood that the invention is notlimited to the disclosed exemplary embodiments. The scope of thefollowing claims is to be accorded the broadest interpretation so as toencompass all such modifications and equivalent structures andfunctions.

This application claims the benefit of Japanese Patent Application No.2012-146086, filed Jun. 28, 2012, which is hereby incorporated byreference herein in its entirety.

1.-19. (canceled)
 20. A setting apparatus for making a setting to detectthat a moving object in an image has passed a line set in the image,comprising: a determination unit configured to determine a position on afigure in accordance with a user's operation; a display control unitconfigured to display, on a display screen, the figure marked at theposition determined by said determination unit; and a setting unitconfigured to make a setting to detect that a determination position onan object region of the moving object in the image has passed the lineset in the image, the determination position corresponding to theposition determined by said determination unit.
 21. The apparatusaccording to claim 20, wherein a selection unit further selects adirection in which the determination position passes the line set in theimage in accordance with a user's selection operation.
 22. The apparatusaccording to claim 20, wherein the display control unit displays thefigure marked at a center of the figure on the display screen inaccordance with the user's operation.
 23. A setting method for a settingapparatus for making a setting to detect that a moving object in animage has passed a line set in the image, the method comprising:determining a position on a figure in accordance with a user'soperation; displaying, on a display screen, the figure marked at thedetermined position; and making a setting to detect that a determinationposition on an object region of the moving object in the image haspassed the line set in the image, the determination positioncorresponding to the determined position.
 24. The method according toclaim 23, further comprising selecting a direction in which thedetermination position passes the line set in the image in accordancewith a user's selection operation.
 25. The method according to claim 23,wherein the figure marked at a center of the figure on the displayscreen is displayed in accordance with the user's operation.
 26. Anon-transitory computer-readable storage medium storing a computerprogram for causing a computer to perform a setting method of making asetting to detect that a moving object in an image has passed a line setin the image, the method comprising: determining a position on a figurein accordance with a user's operation; displaying, on a display screen,the figure marked at the determined position; and making a setting todetect that a determination position on an object region of the movingobject in the image has passed the line set in the image, thedetermination position corresponding to the determined position.
 27. Thestorage medium according to claim 26, wherein the setting method furthercomprises selecting a direction in which the determination positionpasses the line set in the image in accordance with a user's selectionoperation.
 28. The storage medium according to claim 26, wherein thefigure marked at a center of the figure on the display screen isdisplayed in accordance with the user's operation.